CastSession

interface CastSession : Observable<T>

A session of casting media content to a media receiver.

The session is discovered when the user starts casting the browser/screen content or a presentation of media content via the JxBrowser API, or another application, i.e. Google Chrome. To indicate that the cast session has been started by another profile and, accordingly, a Chromium instance the isLocal method is provided.

Since

7.29

See also

Functions

Link copied to clipboard
abstract fun description(): String
Returns the description of the session.
Link copied to clipboard
abstract fun isAlive(): Boolean
Returns true if the session is alive.
Link copied to clipboard
abstract fun isLocal(): Boolean
Returns true if the cast session is initiated and managed by the current profile.
Link copied to clipboard
Returns the media receiver of this session.
Link copied to clipboard
abstract fun mode(): CastMode
Returns the mode of the session.
Link copied to clipboard
abstract fun <E : T?> on(eventClass: Class<E>, observer: Observer<E>): Subscription
Subscribes the given event observer to receive the events of the given eventClass.
Link copied to clipboard
abstract fun profile(): Profile
Returns the profile that discovered this cast session.
Link copied to clipboard
abstract fun stop()
Stops this cast session.
Link copied to clipboard
inline fun <E : Event> Observable<in E>.subscribe(observer: Observer<E>): Subscription
inline fun <E : Event> Observable<in E>.subscribe(observer: Observer<E>): Subscription

Subscribes the given observer to receive events of type E from this Observable.